<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
	<title>爱家家具商城后台管理系统</title>
	<link rel="stylesheet" type="text/css" href="js/jquery-easyui-1.4.1/themes/gray/easyui.css" />
	<link rel="stylesheet" type="text/css" href="js/jquery-easyui-1.4.1/themes/icon.css" />
	<link rel="stylesheet" type="text/css" href="css/lp.css" />
	<link rel="stylesheet" type="text/css" href="css/default.css" />
	<script type="text/javascript" src="js/jquery-easyui-1.4.1/jquery.min.js"></script>
	<script type="text/javascript" src="js/jquery-easyui-1.4.1/jquery.easyui.min.js"></script>
	<script type="text/javascript" src="js/jquery-easyui-1.4.1/locale/easyui-lang-zh_CN.js"></script>
	<script type="text/javascript" src="js/common.js"></script>
	<style type="text/css">
		.content {
			padding: 10px 10px 10px 10px;
		}
	</style>
</head>
<body class="easyui-layout">
<!-- 头部标题 -->
<div data-options="region:'north',border:false" style="height:60px; padding:5px; background:#F3F3F3">
	<span class="northTitle">爱家家具商城后台管理系统</span>
	<span class="loginInfo">登录用户：${sessionScope.adminMessage.account}&nbsp;&nbsp;姓名：${sessionScope.adminMessage.name}&nbsp;&nbsp;角色：系统管理员</span>
	<span class="logout" data-options="attributes:{'url':'admin/logout'}">退出登录</span>
</div>
<div data-options="region:'west',title:'菜单',split:true" style="width:180px;">
	<ul id="menu" class="easyui-tree" style="margin-top: 10px;margin-left: 5px;">
		<li>
			<span>商品管理</span>
			<ul>
				<li data-options="attributes:{'url':'product-add'}">新增商品</li>
				<li data-options="attributes:{'url':'item-list'}">查询商品</li>
				<li data-options="attributes:{'url':'item-param-list'}">规格参数</li>
			</ul>
		</li>
		<li>
			<span>网站内容管理</span>
			<ul>
				<li data-options="attributes:{'url':'content-category'}">内容分类管理</li>
				<li data-options="attributes:{'url':'content'}">内容管理</li>
			</ul>
		</li>
		<li>
			<span>索引库管理</span>
			<ul>
				<li data-options="attributes:{'url':'index-item'}">solr索引库维护</li>
			</ul>
		</li>
	</ul>
</div>
<div data-options="region:'center',title:''">
	<div id="tabs" class="easyui-tabs">
		<div title="首页" style="padding:20px;">

		</div>
	</div>
</div>
<!-- 页脚信息 -->
<div data-options="region:'south',border:false" style="height:20px; background:#F3F3F3; padding:2px; vertical-align:middle;">
	<span id="sysVersion">系统版本：V1.0</span>
	<span id="nowTime"></span>
</div>
<script type="text/javascript">
	$(function(){
		$('#menu').tree({
			onClick: function(node){
				if($('#menu').tree("isLeaf",node.target)){
					var tabs = $("#tabs");
					var tab = tabs.tabs("getTab",node.text);
					if(tab){
						tabs.tabs("select",node.text);
					}else{
						tabs.tabs('add',{
							title:node.text,
							href: node.attributes.url,
							closable:true,
							bodyCls:"content"
						});
					}
				}
			}
		});
		$('.logout').click(function () {

			$.ajax({
				type:"get",
				url:"admin/logout",
				data:"",
				success:function(result){
					window.location.href="/";
				}
			})
		});
	});
	setInterval("document.getElementById('nowTime').innerHTML=new Date().toLocaleString()+' 星期'+'日一二三四五六'.charAt(new Date().getDay());",1000);
</script>
</body>
</html>